<template>
  <el-descriptions v-bind="$attrs">
    <el-descriptions-item
      :label="item.label"
      v-for="(item, index) in itemList"
      :key="index"
    >
      <template v-if="!item.slot"> {{ item.value }}</template>
      <slot :name="item.slot"></slot>
    </el-descriptions-item>
  </el-descriptions>
</template>
<script setup>
const props = defineProps({
  itemList: {
    type: Array,
    default: () => {
      return [];
    },
  },
});
</script>
